{
 "cells": [
  {
   "cell_type": "raw",
   "metadata": {
    "raw_mimetype": "text/restructuredtext"
   },
   "source": [
    ".. _nb_gde3_dynamic:"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Dynamic GDE3"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Example"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {
    "pycharm": {
     "is_executing": false,
     "name": "#%%\n"
    }
   },
   "outputs": [],
   "source": [
    "from jmetal.algorithm.multiobjective.gde3 import DynamicGDE3\n",
    "from jmetal.problem.multiobjective.fda import FDA2\n",
    "from jmetal.util.observable import TimeCounter\n",
    "from jmetal.util.observer import PlotFrontToFileObserver, WriteFrontToFileObserver\n",
    "from jmetal.util.termination_criterion import StoppingByEvaluations\n",
    "\n",
    "problem = FDA2()\n",
    "\n",
    "time_counter = TimeCounter(delay=1)\n",
    "time_counter.observable.register(problem)\n",
    "time_counter.start()\n",
    "\n",
    "algorithm = DynamicGDE3(\n",
    "    problem=problem,\n",
    "    population_size=100,\n",
    "    cr=0.5,\n",
    "    f=0.5,\n",
    "    termination_criterion=StoppingByEvaluations(max=500)\n",
    ")\n",
    "\n",
    "algorithm.observable.register(observer=PlotFrontToFileObserver('front_plot'))\n",
    "algorithm.observable.register(observer=WriteFrontToFileObserver('front_files'))\n",
    "\n",
    "algorithm.run()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### API"
   ]
  },
  {
   "cell_type": "raw",
   "metadata": {
    "pycharm": {
     "is_executing": false,
     "name": "#%% raw\n"
    },
    "raw_mimetype": "text/restructuredtext"
   },
   "source": [
    ".. autoclass:: jmetal.algorithm.multiobjective.gde3.DynamicGDE3\n",
    "   :members:\n",
    "   :undoc-members:\n",
    "   :show-inheritance:\n"
   ]
  }
 ],
 "metadata": {
  "celltoolbar": "Raw Cell Format",
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.3"
  },
  "pycharm": {
   "stem_cell": {
    "cell_type": "raw",
    "source": [],
    "metadata": {
     "collapsed": false
    }
   }
  }
 },
 "nbformat": 4,
 "nbformat_minor": 1
}